<template>
  <div>
    <el-form :inline="true" :model="formInline" class="demo-form-inline">
      <el-form-item label="标题:">
        <el-input size="small" v-model="formInline.title" placeholder="请输入标题"></el-input>
      </el-form-item>
      <el-form-item label="来源:">
        <el-select  size="small" v-model="formInline.sourceSystem" placeholder="请选择来源" clearable>

          <el-option v-for="item in list" :label="item.sourceSystem"
                     :value="item.sourceSystem"></el-option>
        </el-select>
      </el-form-item>
<!--      <el-form-item label="发起人:">
        <el-input  size="small" v-model="formInline.promoterName" placeholder="请输入发起人"></el-input>
      </el-form-item>-->
      <el-form-item>
        <el-button  size="small" type="primary" @click="onSubmit">查询</el-button>
        <el-button   type="info" size="small"
                     plain  @click="formInline={}">重置</el-button>
      </el-form-item>
    </el-form>
  </div>
</template>

<script>
export default {
  name: "searchForm",
  data() {
    return {
      list:[],
      formInline: {
        title:'',
        sourceSystem:'',
        promoterName:''
      }
    }
  },
  created() {
    //this.getPer()
  },
  methods: {
    onSubmit() {
      console.log('submit!');
      this.$emit('sub')
    },
    getPer(){
      this.$api.querySystemSource().then(res=>{
        this.list=res.data
      }).catch()
    }
  }
}
</script>

<style scoped>

</style>
